<%@ page import="com.dzzw.Model.Admin" %>
<%@ page import="java.util.List" %>
<%@ page import="com.dzzw.utils.Page" %>
<%@ page import="com.dzzw.Dao.AdminDao" %>
<%--
  Created by IntelliJ IDEA.
  User: 10391
  Date: 2021/3/14
  Time: 16:52
  To change this template use File | Settings | File Templates.
--%>
<%--<%
    Page thpage = new Page();
    AdminDao adminDao = new AdminDao();
    String sql = "select * from t_admin limit "+thpage.getBeginIndex()+","+thpage.getEveryPage();
    List<Admin> list = adminDao.SelectAdminList(sql);
    request.setAttribute("list",list);
%>--%>
<%@ page import="com.dzzw.Model.*" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" isELIgnored="false"  pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core"  prefix = "c" %>
<!DOCTYPE html>
<html>
<head>
    <title>查询管理员信息</title>
</head>
<body>
    <table class="content">
        <tr>
            <td>管理员 ID</td>
            <td>管理员账号</td>
            <td>管理员姓名</td>
            <td>管理员密码</td>
        </tr>
        <c:forEach items="${requestScope.list}" var="admin">
        <tr>
            <td>${admin.admin_id}</td>
            <td>${admin.admin_actnumber}</td>
            <td>${admin.admin_name}</td>
            <td>${admin.admin_password}</td>
        </tr>
        </c:forEach>
    </table>
    <a href="SelectAdminList?currentPage=1">首页</a>&nbsp;&nbsp;
    <c:if test="${sessionScope.page.currentPage !=1}">
        <a href="SelectAdminList?currentPage=${sessionScope.page.currentPage-1}">上一页</a>&nbsp;&nbsp;
    </c:if>
    <c:if test="${sessionScope.page.currentPage !=sessionScope.page.totalPage}">
        <a href="SelectAdminList?currentPage=${sessionScope.page.currentPage+1}">下一页</a>&nbsp;&nbsp;
    </c:if>
    <a href="SelectAdminList?currentPage=${sessionScope.page.totalPage}">尾页</a>
</body>
</html>

